//
//  GZLogItem.h
//  GZLogger
//
//  Created by GR on 2018/12/20.
//  Copyright © 2018 GR. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "GZLogLevel.h"

NS_ASSUME_NONNULL_BEGIN

@interface GZLogItem : NSObject

// 时间
@property (readonly) NSTimeInterval timestamp;
@property (readonly) NSDate *time;

// Trace
@property (readonly) NSString *file;
@property (readonly) NSUInteger line;
@property (readonly) NSString *function;

// 级别
@property (readonly) GZLogLevel level;
@property (readonly) NSString *levelText;

// 标签
@property (readonly) NSString *tag;

// 文本内容
@property (readonly) NSString *content;

// 栈信息
@property (readonly) NSUInteger stackLevel;
@property (readonly) NSString *stackSymbols;

// 文件
@property (readonly) NSString *dataFileName;

+ (instancetype)itemWithTimestamp:(NSTimeInterval)timestamp
                             file:(NSString *)file
                             line:(NSUInteger)line
                         function:(NSString *)function
                            level:(GZLogLevel)level
                              tag:(NSString *)tag
                          content:(NSString *)content
                       stackLevel:(NSUInteger)stackLevel
                     dataFileName:(NSString *)dataFileName;

@end

NS_ASSUME_NONNULL_END
